Population class extension: population_options_defaults module
- Module that contains the default options for the population grid code along with the description for these options, in the form of dictionaries:
population_options_defaults_dict: dictionary containing the default values for all the options
population_options_descriptions: dictionary containing the description for these options.
- There are several other functions in this module, mostly to generate help texts or documents:
population_options_help: interactive function for the user to get descriptions for options
write_population_options_to_rst_file: function to generate the .rst document for the docs
With this its also possible to automatically generate a document containing all the setting names + descriptions.
All the options starting with _ should not be changed by the user except when you really know what you’re doing (which is probably hacking the code :P)
- binarycpython.utils.population_extensions.population_options_defaults.callable_validation(value)[source]
- binarycpython.utils.population_extensions.population_options_defaults.capsule_validation(value)[source]
- binarycpython.utils.population_extensions.population_options_defaults.iterator_validation(value)[source]
- class binarycpython.utils.population_extensions.population_options_defaults.population_options_defaults(**kwargs)[source]
Bases:
object
Class extension to Population grid containing all the functionality for the options and defaults
- build_description_table(table_name, parameter_list, description_dict)[source]
Function to create a table containing the description of the options
- parse_description(description_dict)[source]
Function to parse the description for a given parameter
- population_options_help(option)[source]
Function that prints out the description of a grid option. Useful function for the user.
- Parameters
option (
str
) – which option you want to have the description of.- Return type
dict
- Returns
dict containing the option, the description if its there, otherwise empty string. And if the key doesnt exist, the dict is empty